Programmable Logic Devices (PLDs) are used in a variety of control applications, such as controllers and/or drivers in industrial applications. PLDs are low-cost devices that can be programmed for specific control applications, such as for operating electric motors, for example. The ability to program PLDs makes them ideal for stand-alone applications.
Because of the widespread use and deployment of PLDs, there is a continuing need to improve the reliability and ease-of-use of such devices. One area for improvement is in programming, wherein it is needed for a user to be able to quickly and easily generate a complete set of programming code for a particular PLD. However, it is also important that the programming be correct and functional, without consuming an excess amount of design and programming time on the part of an engineer or other user.
A prior art approach to programming PLD devices is to re-use existing programming, wherein the existing programming may be modified and then used in a new application, wherein existing programs are commonly modified and then re-used in some fashion. However, this introduces a danger of improper or incomplete programming because of the differences between an original PLD and a newly-modified PLD, which may result in more lost time, rather than less time consumed in the programming of the PLD device. In addition, there is a danger that unneeded portions of the code may be retained, wherein the retained code occupies memory space and in some situations may result in improper behavior of the PLD or associated device.
Overview
In an embodiment, a PLD editor for editing PLD code to be programmed into a PLD is provided. The PLD editor includes an interface for communicating with the PLD, a storage system for storing the PLD code, a library of PLD devices, and a library of logic instruction blocks, and a processing system coupled to the interface and the storage system, with the processing system configured to obtain a PLD code, with the PLD code comprising one or more logic instruction blocks and corresponding block parameters for each logic instruction block, with the PLD code being intended for programming into the PLD, compare the one or more logic instruction blocks of the PLD code to a subset of the library of logic instruction blocks applicable to the PLD according to the library of PLD devices, determine inconsistent logic instruction blocks of the one or more logic instruction blocks, indicate the inconsistent logic instruction blocks, and correct the inconsistent logic instruction blocks using the subset of the library of logic instruction blocks.
This Overview is provided to introduce a selection of concepts in a simplified form that are further described below in the Technical Disclosure. It should be understood that this Overview is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.